package abstract_factory;

public class AutomobileFactory extends AbstractFactory{

    @Override
    public Car getAutomobileFactoryBrand(String automobileManufacturer) {
        //工厂注册了自家车品牌，以不同的品牌名来区分并且联系他们。
        if(automobileManufacturer.equals("Audi")){
            return new AuDi();
        }else if (automobileManufacturer.equals("BMW")){
            return new BMW();
        }
        return null;
    }

    @Override
    public Bread getBreadFactoryBrand(String breadManufacturer) {
        return null;
    }
}
